<template>
  <el-row>
    <div>行->[{{rows.join(',')}}]</div>
    <div>列->[{{cols.join(',')}}]</div>
    <div>选项->[{{options.join(',')}}]</div>
  </el-row>
</template>

<script>
  export default {
    name: "view-i-table",
    props:['question'],
    computed:{
      rows(){
        let tmp = []
        this.question.rows.forEach(r=>tmp.push(r.text))
        return tmp
      },
      cols(){
        let tmp = []
        this.question.cols.forEach(r=>tmp.push(r.text))
        return tmp
      },
      options(){
        let tmp = []
        if(this.question.options)
        this.question.options.forEach(r=>tmp.push(r.text))
        return tmp
      }
    }
  }
</script>

<style lang="scss">

</style>
